Skip to content

gh-161766: Remove stale awaited-by edges from as_completed - #162041

Open
parthkale275 wants to merge 4 commits into
python:mainfrom
parthkale275:parthkale275-fix-issue-161766
Open

parthkale275 wants to merge 4 commits into
python:mainfrom
parthkale275:parthkale275-fix-issue-161766

Conversation

@parthkale275

@parthkale275 parthkale275 commented Nov 15, 2026 •

Copy link
Copy Markdown

Summary

  • Remove as_completed() awaited-by edges when the consuming task finishes.
  • Omit completed waiters from awaited-by snapshots so call graphs do not show stale consumers before cleanup callbacks run.
  • Add a regression test for exiting early after one child fails.

Fixes #161766

Testing

  • Python AST parse of the modified Python files — passed (syntax check only).
  • Asyncio runtime tests — not run; this worktree has no built CPython interpreter or Visual Studio compiler.

Assisted with GitHub Copilot.

@python-cla-bot

python-cla-bot Bot commented Nov 15, 2026 •

Copy link
Copy Markdown

All commit authors signed the Contributor License Agreement.

CLA signed

@bedevere-app

bedevere-app Bot commented Nov 15, 2026

Copy link
Copy Markdown

Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool.

If this change has little impact on Python users, wait for a maintainer to apply the skip news label instead.

@parthkale275
parthkale275 force-pushed the parthkale275-fix-issue-161766 branch from 259d2e2 to a405f36 Compare November 15, 2026 13:16
@bedevere-app

bedevere-app Bot commented Nov 15, 2026

Copy link
Copy Markdown

Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool.

If this change has little impact on Python users, wait for a maintainer to apply the skip news label instead.

@bedevere-app

bedevere-app Bot commented Nov 15, 2026

Copy link
Copy Markdown

Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool.

If this change has little impact on Python users, wait for a maintainer to apply the skip news label instead.

@parthkale275
parthkale275 force-pushed the parthkale275-fix-issue-161766 branch from 3376834 to 890163a Compare November 15, 2026 17:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

asyncio.as_completed() leaves stale awaited_by edges when the loop exits early

1 participant